@search-prefix-cls: ~'@{css-prefix}search';
@input-prefix-cls: ~'@{css-prefix}input';
@input-group-prefix-cls: ~'@{css-prefix}input-group';

.@{search-prefix-cls} {
  .haloe-icon-close-circle-filled:before {
    color: @search-icon-close-circle;
  }
  .haloe-input-search:before {
    width: 0;
  }
  .@{input-prefix-cls} {
    border-color: @color-scrollbar !important;
    &-no-border {
      border: none;
    }
    &-prefix i {
      color: @color-complementary-5;
    }

    &-search {
      z-index: 1;
      padding: 0 10px !important;
      background: @color-functional-white !important;
      color: @color-complementary-5 !important;
      border-color: @color-scrollbar !important;

      &:hover {
        color: @color-brand-primary !important;
        border: 1px solid @color-brand-primary !important;
      }
    }
    // &-group-prepend {
    //   border: 1px solid @color-border-disable !important;
    // }
    // &-group-prepend:hover {
    //   border-color: @color-brand-primary !important;
    //   // border-right: 1px solid red !important;
    // }
    &:hover {
      border-color: @color-brand-primary !important;
    }
  }

  .@{input-group-prefix-cls} {
    &-wrapper > *:last-child.@{input-prefix-cls}-wrapper .@{input-prefix-cls} {
      border-top-right-radius: 0 !important;
      border-bottom-right-radius: 0 !important;
    }

    &-wrapper
      > *:first-child.@{input-prefix-cls}-group-with-prepend
      .@{input-prefix-cls} {
      border-top-left-radius: 0 !important;
      border-bottom-left-radius: 0 !important;
    }
  }

  &-disabled {
    .haloe-icon-search:before {
      color: @search-icon-disabled-prefix !important;
    }
    .haloe-select-selected-value {
      color: @search-icon-disabled-prefix !important;
    }
    .haloe-select-selection,
    .haloe-select-selection:hover {
      border-color: @color-border-disable !important;
      border-right: 0 !important;
    }
    .@{input-prefix-cls} {
      border-color: @color-complementary-7 !important;
      &-search,
      &-search:hover {
        cursor: @cursor-disabled;
        background: @color-complementary-8 !important;
        color: @search-icon-disabled-prefix !important;
        border-color: @color-border-disable !important;
      }
    }
  }
  .haloe-input-wrapper-disabled .haloe-input:not(.haloe-input-no-border) {
    border: 1px solid @color-border-disable !important;
  }
}
